<template>
  <div>
    主页
    <el-button type="success" @click="open2">Success</el-button>
  </div>
</template>

<script setup>
import { ElMessage } from 'element-plus'
const open2 = () => {
  ElMessage({
    message: 'Congrats, this is a success message.',
    type: 'success',
  })
}
</script>

<style lang="scss" scoped>

</style>